package com.qdlc.p2p.dal.dto;

import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;

import com.qdlc.p2p.common.constant.Global;

/**
 * 用户托管资金差额表
 *
 * @author liya
 * @version 1.1.0.0
 */
@Entity
@Table(name = Global.DB_PREFIX + "tpp_difference")
public class TppDifference {

    /** 主键 */
    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    private long id;

    /** 用户ID */
    @OneToOne(fetch = FetchType.LAZY)
    @JoinColumn(name = "user_id")
    private User user;

    /** 处理状态 0：未处理 1：已处理 */
    private int status;

    /** 账户余额 */
    private double total;

    /** 托管账户余额 */
    private double tppTotal;

    /** 余额差额 */
    private double differenceTotal;

    /** 可用余额 */
    private double useMoney;

    /** 托管可用余额 */
    private double tppUseMoney;

    /** 可用余额差额 */
    private double differenceUse;

    /** 冻结总额 */
    private double noUseMoney;

    /** 托管冻结总额 */
    private double tppNoUseMoney;

    /** 总冻结差额 */
    private double differenceNoUse;

    /** 添加时间 */
    private Date addTime;

    /** 更新时间 */
    private Date updateTime;

    /** 备注 */
    private String remark;

    public TppDifference() {
        super();
    }

    public TppDifference(User user) {
        super();
        this.user = user;
    }

    /**
     * 获取主键
     *
     * @return 主键
     */
    public long getId() {
        return id;
    }

    /**
     * 设置主键
     *
     * @param id 要设置的主键
     */
    public void setId(long id) {
        this.id = id;
    }

    /**
     * 获取用户ID
     *
     * @return 用户ID
     */
    public User getUser() {
        return user;
    }

    /**
     * 设置用户
     *
     * @param user 要设置的用户
     */
    public void setUser(User user) {
        this.user = user;
    }

    public double getTppTotal() {
        return tppTotal;
    }

    public void setTppTotal(double tppTotal) {
        this.tppTotal = tppTotal;
    }

    public double getTppUseMoney() {
        return tppUseMoney;
    }

    public void setTppUseMoney(double tppUseMoney) {
        this.tppUseMoney = tppUseMoney;
    }

    public double getDifferenceUse() {
        return differenceUse;
    }

    public void setDifferenceUse(double differenceUse) {
        this.differenceUse = differenceUse;
    }

    public double getTppNoUseMoney() {
        return tppNoUseMoney;
    }

    public void setTppNoUseMoney(double tppNoUseMoney) {
        this.tppNoUseMoney = tppNoUseMoney;
    }

    public double getDifferenceNoUse() {
        return differenceNoUse;
    }

    public void setDifferenceNoUse(double differenceNoUse) {
        this.differenceNoUse = differenceNoUse;
    }

    public Date getAddTime() {
        return addTime;
    }

    public void setAddTime(Date addTime) {
        this.addTime = addTime;
    }

    public double getTotal() {
        return total;
    }

    public void setTotal(double total) {
        this.total = total;
    }

    public double getUseMoney() {
        return useMoney;
    }

    public void setUseMoney(double useMoney) {
        this.useMoney = useMoney;
    }

    public double getNoUseMoney() {
        return noUseMoney;
    }

    public void setNoUseMoney(double noUseMoney) {
        this.noUseMoney = noUseMoney;
    }

    public double getDifferenceTotal() {
        return differenceTotal;
    }

    public void setDifferenceTotal(double differenceTotal) {
        this.differenceTotal = differenceTotal;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

}
